<!DOCTYPE html>
<html>
<head>
    <title> {$site_info.site_name|default=''}</title>
    <meta name="keywords" content="{$site_info.site_seo_keywords|default=''}"/>
    <meta name="description" content="{$site_info.site_seo_description|default=''}">
    <include file="public@head"/>
    <hook name="before_head_end"/>
</head>
<body class="page-index">
<div class="container">
    <include file="public@nav"/>

    <div class="contents">
        <!--左侧导航-->
        <div class="personalLeft">
                <div class="logoTx">
                <img src="{$user.avatar}" class="logoTxImg">
                <div class="personalName">{$user.user_nickname}</div>
            </div>

            <div class="navigation">
                <ul>
                    <li class="backSty" data-menu="{:url('portal/Personal/per_data')}">
                        <text class="lineSty"></text>
                        <a href="javascript:;">
                            <i class="layui-icon layui-icon-form navigaIcon"></i> 资料管理
                        </a>
                    </li>
                    <li data-menu="{:url('portal/Personal/per_activity')}">
                        <text class="lineSty"></text>
                        <a href="javascript:;">
                            <i class="layui-icon layui-icon-release navigaIcon"></i> 活动管理
                        </a>
                    </li>
                    <li data-menu="{:url('portal/Personal/per_article')}">
                        <text class="lineSty"></text>
                        <a href="javascript:;">
                            <i class="layui-icon layui-icon-template-1 navigaIcon"></i> 文章管理
                        </a>
                    </li>
                    <li data-menu="{:url('portal/Personal/per_integral')}">
                        <text class="lineSty"></text>
                        <a href="javascript:;">
                            <i class="layui-icon layui-icon-diamond navigaIcon"></i> 积分管理
                        </a>
                    </li>
                </ul>
            </div>
        </div>
        <!--右侧内容-->
        <div class="personalRight">
            <div class="layui-body layui-form">
                <div class="layui-tab mag0" lay-filter="bodyTab" id="top_tabs_box">
                    <div class="layui-tab-content clildFrame">
                        <div class="layui-tab-item layui-show" id="h5SourceShow">
                            <iframe id="iframe" src="{:url('portal/Personal/per_data')}"></iframe>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div style="clear: both;"></div>
    </div>


    <include file="public@footer"/>
    <!-- /container -->
    <include file="public@scripts"/>
    <script>
        (function($){
            "use strict";
            function height() {
                setTimeout(function () {
                    var mainheight = $("#iframe").contents().find("#personHeight").height();
                    $(".personalRight").css("height",mainheight);
                },100);
            }
            function bind_events(){
                $('.navigation ul li').off("click").on("click",function(){
                    $(this).find('text').css("display","block");
                    $(this).siblings().find("text").css("display","none");
                    var _url = "'"+ $(this).data("menu")+"'";
                    $(this).addClass('backSty').siblings().removeClass('backSty');
                    var iframe = '<iframe id="iframe" src='+ _url +'></iframe>';
                    $('#iframe').remove();
                    $('#h5SourceShow').html(iframe);
                    height();
                });
            };
            $(function(){
                $(".navigation ul li:first").find("text").css("display","block");
                height();
                bind_events();
            })
        })(jQuery)
    </script>
    <hook name="before_body_end"/>
</body>
</html>